home *** CD-ROM | disk | FTP | other *** search
/ VRML 2.0 Sourcebook (2nd Edition) / VRML 2.0 Sourcebook CD [md5 fed90f4f9c39d5a60d477058775c7e21].iso / book / win / ch18 / 18fig21.wrl < prev    next >
Text File  |  1996-09-23  |  2KB  |  81 lines

  1. #VRML V2.0 utf8
  2. # The VRML 2.0 Sourcebook
  3. # Copyright [1997] By
  4. # Andrea L. Ames, David R. Nadeau, and John L. Moreland
  5. Shape {
  6.     appearance Appearance {
  7.         material Material { }
  8.         texture ImageTexture {
  9.             url "pizza.jpg"
  10.         }
  11.     }
  12.     geometry IndexedFaceSet {
  13.         coord Coordinate {
  14.             point [
  15.             # Slice, pulled out of pizza
  16.                  0.50 0.0  0.50,   0.88 0.0  1.42,
  17.                  1.06 0.0  1.33,   1.21 0.0  1.21,
  18.                  1.33 0.0  1.06,   1.42 0.0  0.88,
  19.             # Rest of pizza
  20.                  0.00 0.0  0.00,   0.92 0.0  0.38,
  21.                  0.98 0.0  0.20,   1.00 0.0  0.00,
  22.                  0.98 0.0 -0.20,   0.92 0.0 -0.38,
  23.                  0.83 0.0 -0.56,   0.71 0.0 -0.71,
  24.                  0.56 0.0 -0.83,   0.38 0.0 -0.92,
  25.                  0.20 0.0 -0.98,   0.00 0.0 -1.00,
  26.                 -0.20 0.0 -0.98,  -0.38 0.0 -0.92,
  27.                 -0.56 0.0 -0.83,  -0.71 0.0 -0.71,
  28.                 -0.83 0.0 -0.56,  -0.92 0.0 -0.38,
  29.                 -0.98 0.0 -0.20,  -1.00 0.0  0.00,
  30.                 -0.98 0.0  0.20,  -0.92 0.0  0.38,
  31.                 -0.83 0.0  0.56,  -0.71 0.0  0.71,
  32.                 -0.56 0.0  0.83,  -0.38 0.0  0.92,
  33.                 -0.20 0.0  0.98,   0.00 0.0  1.00,
  34.                  0.20 0.0  0.98,   0.38 0.0  0.92
  35.             ]
  36.         }
  37.         coordIndex [
  38.         # Slice
  39.              0,  1,  2,  3,  4,  5, -1,
  40.         # Rest of pizza
  41.              6,  7,  8,  9, 10, 11, 12, 13, 14, 15, 16,
  42.             17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27,
  43.             28, 29, 30, 31, 32, 33, 34, 35
  44.         ]
  45.         texCoord TextureCoordinate {
  46.             point [
  47.             # Center point of pizza image
  48.                 0.50 0.50,
  49.             # Pizza perimeter
  50.                 0.96 0.41,  0.97 0.50,
  51.                 0.96 0.59,  0.93 0.68,
  52.                 0.89 0.76,  0.83 0.83,
  53.                 0.76 0.89,  0.68 0.93,
  54.                 0.59 0.96,  0.50 0.97,
  55.                 0.41 0.96,  0.32 0.93,
  56.                 0.24 0.89,  0.17 0.83,
  57.                 0.11 0.76,  0.07 0.68,
  58.                 0.04 0.59,  0.03 0.50,
  59.                 0.04 0.41,  0.07 0.32,
  60.                 0.11 0.24,  0.17 0.17,
  61.                 0.24 0.11,  0.32 0.07,
  62.                 0.41 0.04,  0.50 0.03,
  63.                 0.59 0.04,
  64.             # Slice perimeter
  65.                 0.68 0.07,  0.76 0.11,
  66.                 0.83 0.17,  0.89 0.24,
  67.                 0.93 0.32
  68.             ]
  69.         }
  70.         texCoordIndex [
  71.         # Slice
  72.             0, 28, 29, 30, 31, 32, -1,
  73.         # Rest of pizza
  74.             0,  32,  1,  2,  3,  4,  5,  6,  7,  8,  9, 10,
  75.             11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22,
  76.             23, 24, 25, 26, 27, 28
  77.         ]
  78.         solid FALSE
  79.     }
  80. }
  81.